#include<iostream>
using namespace std;

void swap(int & a, int & b);

int main()
{
	int wallet1 = 10, wallet2 = 20;
	cout << "before swap:\n" << "wallet1:" << wallet1 << endl << "wallet2:" << wallet2 << endl; 
	swap(wallet1, wallet2);
	cout << "after swap:\n" << "wallet1:" << wallet1 << endl << "wallet2:" << wallet2 << endl; 
	return 0;
}

void swap(int & a, int & b)
{
	int t = a;
	a = b;
	b = t;
}
